package com.foryou.wechat.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * Created by Lee.
 */
@Data
@TableName("v_user_follow")
@NoArgsConstructor
public class UserFollowEntity extends BaseEntity {

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;
    //我关注了哪些人：from_user_id是我的ID
    private Long fromUserId;
    //这页显示的是我的粉丝：别人关注我的
    private Long toUserId;
    private String bothStatus;

    @TableField(exist = false)
    private UserEntity userEntity;

    public UserFollowEntity(Long fromUserId, Long toUserId, String bothStatus) {
        this.fromUserId = fromUserId;
        this.toUserId = toUserId;
        this.bothStatus = bothStatus;
    }
}
